import React from 'react';
import PropTypes from 'prop-types'
import './inputAdd.css';
import { Input } from 'antd';
const Search = Input.Search;


const inputUI = (props) =>{
    const { inputValue,handleChangeInputValue,handleAddItem } = props;
    return (
        <div className="Input">
         <Search
            placeholder="input search text"
            enterButton="Add"
            value={inputValue}
            style={{ width: 300 }}
            onChange={handleChangeInputValue}
            onSearch={handleAddItem}
            />
      </div>
    )
}


inputUI.propTypes = {
    inputValue:PropTypes.string.isRequired,
    handleChangeInputValue:PropTypes.func.isRequired,
    handleAddItem:PropTypes.func.isRequired
}

export default inputUI;
